package com.baomidou.mybatisplus.samples.quickstart.controller;

import com.baomidou.mybatisplus.samples.quickstart.entity.User;
import com.baomidou.mybatisplus.samples.quickstart.service.UserService;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.util.List;

@RestController
public class UserController {
    @Resource
    UserService userService;

    @GetMapping("/user/list")
    public List<User> getByName(){
        return userService.getByName();
    }

    @GetMapping("/user/userUrl")
    public String getUserUrl(){
        return userService.getUserUrl();
    }

}
